package com.dfbz.bigdata.modules.system.doman;



import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 
 * @TableName tb_uandd_express
 */
@TableName(value ="tb_uandd_express")
@Data
public class UanddExpress implements Serializable {
    /**
     * 物流id
     */
    @TableId
    private Long expressId;
    /**
     * 物流单号
     */
    private String expressNumber;

    /**
     * 发货地址
     */
    private String deliveryAdd;

    /**
     * 收货地址
     */
    private String takeAdd;

    /**
     * 订单id
     */
    private String odId;

    /**
     * 物流状态 1待付款，2待派送，3已派送，4已完成，5已取消
     */
    private Integer expressStatus;

    /**
     * 创建时间
     */
    @JsonFormat(shape=JsonFormat.Shape.STRING,pattern="yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date createTime;

    /**
     * 更新时间
     */
    @JsonFormat(shape=JsonFormat.Shape.STRING,pattern="yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date updateTime;

    /**
     * 创建人
     */
    private Long createUser;

    /**
     * 修改人
     */
    private Long updateUser;

    /**
     * 是否删除
     */

    private Integer isDeleted;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        UanddExpress other = (UanddExpress) that;
        return (this.getExpressId() == null ? other.getExpressId() == null : this.getExpressId().equals(other.getExpressId()))
            && (this.getDeliveryAdd() == null ? other.getDeliveryAdd() == null : this.getDeliveryAdd().equals(other.getDeliveryAdd()))
            && (this.getTakeAdd() == null ? other.getTakeAdd() == null : this.getTakeAdd().equals(other.getTakeAdd()))
            && (this.getOdId() == null ? other.getOdId() == null : this.getOdId().equals(other.getOdId()))
            && (this.getExpressStatus() == null ? other.getExpressStatus() == null : this.getExpressStatus().equals(other.getExpressStatus()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()))
            && (this.getCreateUser() == null ? other.getCreateUser() == null : this.getCreateUser().equals(other.getCreateUser()))
            && (this.getUpdateUser() == null ? other.getUpdateUser() == null : this.getUpdateUser().equals(other.getUpdateUser()))
            && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getExpressId() == null) ? 0 : getExpressId().hashCode());
        result = prime * result + ((getDeliveryAdd() == null) ? 0 : getDeliveryAdd().hashCode());
        result = prime * result + ((getTakeAdd() == null) ? 0 : getTakeAdd().hashCode());
        result = prime * result + ((getOdId() == null) ? 0 : getOdId().hashCode());
        result = prime * result + ((getExpressStatus() == null) ? 0 : getExpressStatus().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        result = prime * result + ((getCreateUser() == null) ? 0 : getCreateUser().hashCode());
        result = prime * result + ((getUpdateUser() == null) ? 0 : getUpdateUser().hashCode());
        result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", expressId=").append(expressId);
        sb.append(", deliveryAdd=").append(deliveryAdd);
        sb.append(", takeAdd=").append(takeAdd);
        sb.append(", odId=").append(odId);
        sb.append(", expressStatus=").append(expressStatus);
        sb.append(", createTime=").append(createTime);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", createUser=").append(createUser);
        sb.append(", updateUser=").append(updateUser);
        sb.append(", isDeleted=").append(isDeleted);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}